from tortoise import fields
from datetime import datetime
from .base import BaseModel, TimestampMixin


class SysRoleMenu(BaseModel, TimestampMixin):
    """角色和菜单关联表"""

    role_id = fields.IntField(description="角色ID")

    menu_id = fields.IntField(description="菜单ID")

    class Meta:
        table = "sys_role_menu"

    def __str__(self):
        return f"{self.menu_id}"